home *** CD-ROM | disk | FTP | other *** search
/ Monster Media 1996 #15 / Monster Media Number 15 (Monster Media)(July 1996).ISO / arc / archview.zip / ARCHVIEW.BAT next >
DOS Batch File  |  1996-04-06  |  2KB  |  104 lines

  1. @echo off
  2. testfile %1 arc arj dwc hap hpk huf hyp ice lzh lzs out pak rar sqz uc2 zip zoo ??_
  3.  
  4. if errorlevel == 98 goto error
  5. if errorlevel == 18 goto expand
  6. if errorlevel == 17 goto zoo
  7. if errorlevel == 16 goto zip
  8. if errorlevel == 15 goto uc2
  9. if errorlevel == 14 goto sqz
  10. if errorlevel == 13 goto rar
  11. if errorlevel == 12 goto pak
  12. if errorlevel == 11 goto out
  13. if errorlevel == 10 goto lzs
  14. if errorlevel == 9 goto lzh
  15. if errorlevel == 8 goto ice
  16. if errorlevel == 7 goto hyp
  17. if errorlevel == 6 goto huf
  18. if errorlevel == 5 goto hpk
  19. if errorlevel == 4 goto hap
  20. if errorlevel == 3 goto dwc
  21. if errorlevel == 2 goto arj
  22. if errorlevel == 1 goto arc
  23. goto end
  24.  
  25. :error
  26. echo Sorry, this file is not viewable.
  27. goto end
  28.  
  29. :arc
  30. arc v %1 /l24
  31. goto end
  32.  
  33. :arj
  34. arj v %1 -jp
  35. goto end
  36.  
  37. :dwc
  38. dwc v %1 |MORE
  39. goto end
  40.  
  41. :hap
  42. hap3 l %1  |MORE
  43. goto end
  44.  
  45. :hpk
  46. hpacka V %1 |MORE
  47. goto end
  48.  
  49. :huf
  50. echo Files of this format cannot be viewed; they must be expanded.
  51. goto end
  52.  
  53. :hyp
  54. hyper -v %1 |MORE
  55. goto end
  56.  
  57. :ice
  58. freeze
  59. goto end
  60.  
  61. :lzh
  62. lha l %1 |MORE
  63. goto end
  64.  
  65. :lzs
  66. larc l %1 |MORE
  67. goto end
  68.  
  69. :out
  70. tar -tv |MORE
  71. ;will look for archive named "tar.out" in current directory
  72. goto end
  73.  
  74. :pak
  75. pak L /sn /MORE %1
  76. goto end
  77.  
  78. :rar
  79. rar v %1 |MORE
  80. goto end
  81.  
  82. :sqz
  83. sqz V %1 |MORE
  84.  
  85. :uc2
  86. uc V %1 |MORE
  87. goto end
  88.  
  89. :zip
  90. pkzip %1 -vnmp
  91. goto end
  92.  
  93. :zoo
  94. zoo V AC %1
  95. goto end
  96.  
  97. :expand
  98. echo Files of this format cannot be viewed; they must be expanded.
  99. goto end
  100.  
  101. :end
  102. echo                         Archview operation complete.
  103. pause
  104.